import style from "./headertop.module.scss";

// const props = {
//     history:null,
//     title:"",
//     path:"",
//     btnInner: message_icon
// }

const headerTop = (props)=>{
 return (
    <header>
        <b className = {style["title"]}>{props.title}</b>
        {props.btnInner
            ? <button className={style["header-btn"]}
                onClick={()=>{
                   if(props.path && props.history) props.history.push(props.path);
                }}
            >{props.btnInner}</button> : null
        }
    </header>
 )
}

export default headerTop